Higher-order Ck basis functions in 1D
The B-spline basis functions are defined according the the recursive formula, illustrated in Fig. 1.
The higher order B-splines are defined by multiplications of one lower order B-splines and the diagonal line, and adding second lower order B-spline, shifted by one integral, and the opposite diagonal line. For example, the second order B-splines are defined by using two pyramids and two lines, shifted by one interval, as illustrated in the figure.
The points can be collected into the so-called knot vector, using some special convention to define B-splines of arbitrary order.
The vector of knots \( [0 \quad 0 \quad 0 \quad 1 \quad 2 \quad 3 \quad 4 \quad 5 \quad 5 \quad 5] \) in which the first and the last knot are repeated 3=2+1 times, defines the second order basis functions. In order to illustrate the basis functions resulting from the various knot vectors, we recommend the attached MATLAB code.
So we now have
\( \xi_1=\xi_2=\xi_3=0, \xi_4=1, \xi_5=2, \xi_6=3, \xi_7=4, \xi_8=\xi_9=\xi_{10}=5 \)
Since the number of knots in the vector has changed, we need to redefine the new zero and first order basis functions (because there will be more of them and they will have different numbering).
Zero-degree basis functions:
\( B_{1,0}=1 \textrm{ for }x\in[\xi_1,\xi_2=[0,0]=\{0\} \), 0 in other points,
\( B_{2,0}=1 \textrm{ for } x\in[\xi_2,\xi_3]=[0,0]=\{0\} \), 0 in other points,
\( B_{3,0}=1 \textrm{ for } x\in[\xi_3,\xi_4]=[0,1] \), 0 in other points,
\( B_{4,0}=1 \textrm{ for } x\in[\xi_4,\xi_5]=[1,2] \), 0 in other points,
\( B_{5,0}=1 \textrm{ for } x\in[\xi_5,\xi_6]=[2,3] \), 0 in other points,
\( B_{6,0}=1 \textrm{ for } x\in[\xi_6,\xi_7]=[3,4] \), 0 in other points,
\( B_{7,0}=1 \textrm{ for } x\in[\xi_7,\xi_8]=[4,5] \), 0 in other points,
\( B_{8,0}=1 \textrm{ for } x\in[\xi_8,\xi_9]=[5,5]=\{5\} \), 0 in other points,
\( B_{9,0}=1 \textrm{ for } x\in[\xi_9,\xi_{10}]=[5,5]=\{5\} \), 0 in other points
Similarly, we need to redefine the first order basis functions for the new knot vector. Let us recall the formula for
\( p=1 \)
\( B_{i,1}(\xi)=\frac{\xi-\xi_i}{\xi_{i+1}-\xi_i}B_{i,0}(\xi)+\frac{\xi_{i+2}-\xi}{\xi_{i+2}-\xi_{i+1}}B_{i+1,0}(\xi) \)
where we insert the next knots:
\( B_{1,1}(\xi)=\frac{\xi-\xi_1}{\xi_{2}-\xi_1}B_{1,0}(\xi)+\frac{\xi_{3}-\xi}{\xi_{3}-\xi_{2}}B_{2,0}(\xi)=\color{red}{\frac{\xi-0}{0-0}B_{1,0}(\xi)}+\color{red}{\frac{0-\xi}{0-0}B_{2,0}(\xi)} =0 \)
\( B_{2,1}(\xi)=\frac{\xi-\xi_2}{\xi_{3}-\xi_2}B_{2,0}(\xi)+\frac{\xi_{4}-\xi}{\xi_{4}-\xi_{3}}B_{3,0}(\xi) ={\color{red}{\frac{\xi-0}{0-0}B_{2,0}(\xi)}}+\frac{1-\xi}{1-0}B_{3,0}(\xi)= 1-\xi \textrm{ for } \xi\in[0,1] \)
\( B_{3,1}(\xi)=\frac{\xi-\xi_3}{\xi_{4}-\xi_3}B_{3,0}(\xi)+\frac{\xi_{5}-\xi}{\xi_{5}-\xi_{4}}B_{4,0}(\xi) = \frac{\xi-0}{1-0}B_{3,0}(\xi)+\frac{2-\xi}{2-1}B_{4,0}(\xi) = \xi \textrm{ for } \xi\in[0,1], 2-\xi \textrm{ for } \xi\in[1,2] \)
\( B_{4,1}(\xi)=\frac{\xi-\xi_4}{\xi_{5}-\xi_4}B_{4,0}(\xi)+\frac{\xi_{6}-\xi}{\xi_{6}-\xi_{5}}B_{5,0}(\xi) = \frac{\xi-1}{2-1}B_{4,0}(\xi)+\frac{3-\xi}{3-2}B_{5,0}(\xi) =\xi-1 \textrm{ for } \xi\in[1,2], 3-\xi\textrm{ for } \xi\in[2,3] \)
\( B_{5,1}(\xi)=\frac{\xi-\xi_5}{\xi_{6}-\xi_5}B_{5,0}(\xi)+\frac{\xi_{7}-\xi}{\xi_{7}-\xi_{6}}B_{6,0}(\xi) = \frac{\xi-2}{3-2}B_{5,0}(\xi)+\frac{4-\xi}{4-3}B_{6,0}(\xi) = \xi-2 \textrm{ for } \xi\in[2,3], 4-\xi\textrm{ for } \xi\in[3,4] \)
\( B_{6,1}(\xi)=\frac{\xi-\xi_6}{\xi_{7}-\xi_6}B_{6,0}(\xi)+\frac{\xi_{8}-\xi}{\xi_{8}-\xi_{7}}B_{7,0}(\xi) = \frac{\xi-3}{4-3}B_{6,0}(\xi)+\frac{5-\xi}{5-4}B_{7,0}(\xi) = \xi-3 \textrm{ for } \xi\in[3,4], 5-\xi\textrm{ for } \xi\in[4,5] \)
\( B_{7,1}(\xi)=\frac{\xi-\xi_7}{\xi_{8}-\xi_7}B_{7,0}(\xi)+\frac{\xi_{9}-\xi}{\xi_{9}-\xi_{8}}B_{8,0}(\xi) = \frac{\xi-4}{5-4}B_{7,0}(\xi)+{\color{red}{\frac{5-\xi}{5-5}B_{8,0}(\xi)}} = \xi-4 \textrm{ for } \xi\in[4,5] \)
\( B_{8,1}(\xi)=\frac{\xi-\xi_8}{\xi_{9}-\xi_8}B_{8,0}(\xi)+\frac{\xi_{10}-\xi}{\xi_{10}-\xi_{9}}B_{9,0}(\xi) = \color{red}{\frac{\xi-5}{5-5}B_{8,0}(\xi)}+\color{red}{\frac{5-\xi}{5-5}B_{9,0}(\xi)}=0 \)
Second degree basis functions are obtained again using the formula
for \( p=2 \), aassuming that the subsequent knots inserted into the denominator must be different, and if they are not different, then the given term is changed to zero. The elements that disappear are marked in red. In the final stage of the derivation, we insert the formulas calculated before \( B_{1,1}(\xi)=0, \) \( B_{2,1}=1-\xi \textrm{ for } \xi\in[0,1], \) \( B_{3,1}=\xi \textrm{ for } \xi\in[0,1], 2-\xi \textrm{ for } \xi\in[1,2], \) \( B_{4,1}=\xi-1 \textrm{ for } \xi\in[1,2], 3-\xi \textrm{ for } \xi\in[2,3], \) \( B_{5,1}=\xi-2 \textrm{ for } \xi\in[2,3], 4-\xi \textrm{ for } \xi\in[3,4], \) \( B_{7,1}=\xi-4 \textrm{ for } \xi\in[4,5], \) i \( B_{8,1}=0 \). At this point, we write down the formulas for up to three elements on which the second-order B-spline function is determined.
\( B_{1,2}(\xi)=\frac{\xi-\xi_1}{\xi_{3}-\xi_1}B_{1,1}(\xi)+\frac{\xi_{4}-\xi}{\xi_{4}-\xi_{2}}B_{2,1}(\xi) = {\color{red}{\frac{\xi-0}{0-0}B_{1,1}(\xi)}}+\frac{1-\xi}{1-0}B_{2,1}(\xi) =\\=(1-\xi)^2 \textrm{ for } \xi\in[0,1] \)
\( B_{2,2}(\xi)=\frac{\xi-\xi_2}{\xi_{4}-\xi_2}B_{2,1}(\xi)+\frac{\xi_{5}-\xi}{\xi_{5}-\xi_{3}}B_{3,1}(\xi) = \frac{\xi-0}{1-0}B_{2,1}(\xi)+\frac{2-\xi}{2-0}B_{3,1}(\xi) = \\ =\frac{\xi-0}{1-0}\left[1-\xi \textrm{ for } \xi\in[0,1]\right]+\frac{2-\xi}{2-0}\left[\xi \textrm{ for } \xi\in[0,1], 2-\xi \textrm{ for } \xi\in[1,2]\right] \\ = \xi (1-\xi) +\frac{1}{2}(2-\xi)\xi \textrm{ for } \xi\in[0,1], \frac{1}{2}(2-\xi)^2 \textrm{ for } \xi\in[1,2]] \)
\( B_{3,2}(\xi)=\frac{\xi-\xi_3}{\xi_{5}-\xi_3}B_{3,1}(\xi)+\frac{\xi_{6}-\xi}{\xi_{6}-\xi_{4}}B_{4,1}(\xi) = \frac{\xi-0}{2-0}B_{3,1}(\xi)+\frac{3-\xi}{3-1}B_{4,1}(\xi) =\\ = \frac{1}{2}\xi \left[\xi \textrm{ for } \xi\in[0,1], 2-\xi \textrm{ for } \xi\in[1,2]\right] + \frac{3-\xi}{2} \left[\xi-1 \textrm{ for } \xi\in[1,2], 3-\xi \textrm{ for } \xi\in[2,3]\right] =\\ = \frac{1}{2}\xi^2 \textrm{ for } \xi\in[0,1], \frac{1}{2}\xi(2-\xi) + \frac{1}{2}(3-\xi)(\xi-1) \textrm{ for } \xi\in[1,2], \frac{1}{2}(3-\xi)^2 \textrm{ for } \xi\in[2,3] \)
\( B_{4,2}(\xi)=\frac{\xi-\xi_4}{\xi_{6}-\xi_4}B_{4,1}(\xi)+\frac{\xi_{7}-\xi}{\xi_{7}-\xi_{5}}B_{5,1}(\xi) = \frac{\xi-1}{3-1}B_{4,1}(\xi)+\frac{4-\xi}{4-2}B_{5,1}(\xi) =\\ = \frac{\xi-1}{3-1}\left[ \xi-1 \textrm{ for } \xi\in[1,2], 3-\xi \textrm{ for } \xi\in[2,3] \right]+\frac{4-\xi}{4-2}\left[ \xi-2 \textrm{ for } \xi\in[2,3], 4-\xi \textrm{ for } \xi\in[3,4] \right] = \\ = \frac{1}{2}(\xi-1)^2\textrm{ for } \xi\in[1,2], \frac{1}{2}(\xi-1)(3-\xi) +\frac{1}{2}(4-\xi)(\xi-2) \textrm{ for } \xi\in[2,3], \frac{1}{2}(4-\xi)^2 \textrm{ for } \xi\in[3,4] \)
\( B_{5,2}(\xi)=\frac{\xi-\xi_5}{\xi_{7}-\xi_5}B_{5,1}(\xi)+\frac{\xi_{8}-\xi}{\xi_{8}-\xi_{6}}B_{6,1}(\xi) = \frac{\xi-2}{4-2}B_{5,1}(\xi)+\frac{5-\xi}{5-3}B_{6,1}(\xi) =\\ =\frac{1}{2}(\xi-2) \left[ \xi-2 \textrm{ for } \xi\in[2,3], 4-\xi \textrm{ for } \xi\in[3,4] \right] +\frac{1}{2}(5-\xi) \left[ \xi-3 \textrm{ for } \xi\in[3,4], 5-\xi \textrm{ for } \xi\in[4,5] \right]=\\ =\frac{1}{2}(\xi-2)^2 \textrm{ for } \xi\in[2,3], \frac{1}{2}(\xi-2)(4-\xi) +\frac{1}{2}(5-\xi)(\xi-3) \textrm{ for } \xi\in[3,4], (5-\xi) \textrm{ for } \xi\in[4,5] \)
\( B_{6,2}(\xi)=\frac{\xi-\xi_6}{\xi_{8}-\xi_6}B_{6,1}(\xi)+\frac{\xi_{9}-\xi}{\xi_{9}-\xi_{7}}B_{7,1}(\xi) = \frac{\xi-3}{5-3}B_{6,1}(\xi)+\frac{5-\xi}{5-4}B_{7,1}(\xi) = \\ = \frac{\xi-3}{5-3} \left[ \xi-3 \textrm{ for } \xi\in[3,4], 5-\xi \textrm{ for } \xi\in[4,5] \right] +\frac{5-\xi}{5-4} \left[ {\color{red}{0}} \right] =\\ =\frac{1}{2}(\xi-3)^2 \textrm{ for } \xi\in[3,4], \frac{1}{2}(\xi-3)(5-\xi) \textrm{ for } \xi\in[4,5] \)
\( B_{7,2}(\xi)=\frac{\xi-\xi_7}{\xi_{9}-\xi_7}B_{7,1}(\xi)+\frac{\xi_{10}-\xi}{\xi_{10}-\xi_{8}}B_{8,1}(\xi) = \frac{\xi-4}{5-4}B_{7,1}(\xi)+{\color{red}{\frac{5-\xi}{5-5}B_{8,1}(\xi)}} =\\= \frac{\xi-4}{5-4}\left[{\color{red}{0}}\right]+{\color{red}{0}} =0 \)
We got six second order basis functions (leaving the last seventh equal to zero), \( B_{1,2},...,B_{6,2} \).